package com.dx.mes.web.login;

import org.apache.wink.json4j.JSONObject;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.io.PrintWriter;
import java.util.HashMap;
import java.util.Map;

/**
 * Created on 2017/9/30.
 */
@Controller
public class PageServlet {
    @Value("${common.url}")
    private String commonURL;

    @RequestMapping("/page.do")
    public void skipPage(HttpServletRequest request,HttpServletResponse response){
        String common_url = commonURL;
        String result = "{\"common_url\":\""+ common_url +"\"}";
        PrintWriter out = null;
        try {
            out = response.getWriter();
            out.write(result);
        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}
